<script type="text/html" template>
    <link rel="stylesheet" href="{{ layui.setter.base }}style/extend/jquery-ui-1.9.2.custom.css?v={{ layui.setter.version }}" media="all"/>
    <link rel="stylesheet" href="{{ layui.setter.base }}style/extend/jquery.autocompleter.css?v={{ layui.setter.version }}" media="all"/>
    <link rel="stylesheet" href="{{ layui.setter.base }}style/declare.css?v={{ layui.setter.version }}" media="all"/>
</script>
<div class="child-box">
    <div class="layui-card layadmin-header">
        <div class="layui-breadcrumb" lay-filter="breadcrumb">
            <a href="javascript:" lay-href=""><i class="iconfont iconhome"></i>首页</a>
            <a><cite>外汇管理</cite></a>
            <a><cite>受益人管理</cite></a>

            <div class="layui-card-header-left" title="刷新" zmark-event="layui.manage.render">
                <i class="layui-icon layui-icon-refresh layui-anim" zmark-anim="layui-anim-rotate"></i>
            </div>
        </div>
    </div>
    <div class="layui-card mt20">
        <div class="layui-card-body table-box">
            <form class="layui-form" method="post" id="form-beneficiary-list" onsubmit="return false" lay-filter="form-beneficiary-list">
                <input type="hidden" name="status"/>
                <div class="layui-row block pb10">
                    <ul class="extra-l fl" id="queryStatus">
                        <li><a href="javascript:" class="curr" status="">全部</a></li>
                        <li><a href="javascript:" status="0">审核中</a></li>
                        <li><a href="javascript:" status="1">已审核</a></li>
                        <li><a href="javascript:" status="2">已驳回</a></li>
                        <li class="fore2">
                            <div class="search-box" style="width: 550px">
                                <div class="layui-row">
                                    <div class="layui-col-md4" style="padding-right: 10px;">
                                        <select  name="payeeType">
                                            <option value="">收款人类型</option>
                                            <option value="1">本公司银行账户</option>
                                            <option value="2">第三方收款人账户</option>
                                        </select>
                                    </div>
                                    <div class="layui-col-md8">
                                        <input type="text" name="keyword" class="layui-input" placeholder="收款人别名/银行账号" style="width: 310px"/>
                                        <button type="submit" class="layui-btn" lay-submit="" lay-filter="search-beneficiary-list"><i class="layui-icon layui-icon-search"></i></button>
                                    </div>
                                </div>
                            </div>
                        </li>
                    </ul>
                    <div class="fr">
                        <button type="button" class="layui-btn" lay-href="/rate/beneficiary/add">添加收款人</button>
                    </div>
                </div>
                <div class="layui-row mt10">
                    <table class="zm-tab beneficiary-tab" id="tab-beneficiary-list">
                        <colgroup>
                            <col width="140">
                            <col width="110">
                            <col width="80">
                            <col width="160">
                            <col width="80">
                            <col width="100">
                            <col width="80">
                            <col width="120">
                        </colgroup>
                        <thead>
                        <tr>
                            <th>收款人别名</th>
                            <th>收款人类型</th>
                            <th>银行所在地区</th>
                            <th>银行名称</th>
                            <th>币种</th>
                            <th>状态</th>
                            <th>创建日期</th>
                            <th>操作</th>
                        </tr>
                        </thead>
                    </table>
                    <div class="blank-list">
                        <i class="iconfont iconwushuju"></i>
                        <dd>无受益人数据</dd>
                    </div>
                    <div class="zm-pagination">
                        <div id="beneficiary-list-pagination"></div>
                    </div>
                </div>
            </form>
        </div>
    </div>
</div>
<script type="text/html" id="tpl-beneficiary-list">
    {{# layui.each(d,function(i,o){ }}
    <tbody>
    <tr class="tr-tb">
        <td>
            <div class="layui-row">
                <a href="javascript:" lay-href="/rate/beneficiary/detail/id={{o.id}}">{{o.payeeAlias}}</a>
            </div>
        </td>
        <td>
            <div class="layui-row">
                {{layui.com.removeNull(o.payeeTypeDesc)}}
            </div>
        </td>
        <td>
            <div class="layui-row">{{layui.com.removeNull(o.bankCountryDesc)}}</div>
        </td>
        <td>
            <div class="layui-row">{{layui.com.removeNull(o.bankName)}}</div>
        </td>
        <td>
            <div class="layui-row">{{layui.com.removeNull(o.currencyDesc)}}</div>
        </td>
        <td>
            {{# if(o.status == '1'){ }}
            <div class="layui-row completed">{{layui.com.removeNull(o.statusDesc)}}</div>
            {{# } }}
            {{# if(o.status == '2'){ }}
            <div class="layui-row {{o.statusId}}">
                <div status-id="{{o.id}}">

                </div>
            </div>
            {{# } }}
            {{# if(o.status == '0'){ }}
            <div class="layui-row waitExamine">{{layui.com.removeNull(o.statusDesc)}}</div>
            {{# } }}
        </td>
        <td>
            <div class="layui-row">{{layui.com.removeNull(o.dateCreated)}}</div>
        </td>
        <td>
            {{# if(o.status == '2'){ }}
            <a href="javascript:" lay-href="/rate/beneficiary/edit/id={{o.id}}"><span class="made">修改</span></a>
            {{# } }}
        </td>
    </tr>
    </tbody>
    {{# }); }}
</script>
<script type="text/html" id="tpl-no-pass">
    <div class="layui-row tooltip">
        <a href="javascript:"><span class="noPass"><i class="iconfont iconjinggao"></i> {{d.statusDesc}}</span></a>
        <div class="tip-box">
            <div class="tip-con" style="width: 240px">
                <p>原因：{{layui.com.removeNull(d.approveResult)}}</p>
            </div>
            <div class="z-arrow z-arrow-left"></div>
        </div>
    </div>
</script>
<script>
    layui.use('rateBeneficiaryList', layui.factory('rateBeneficiaryList'));
</script>
<style type="text/css">
    .zm-tab tbody td {
        border-left: none;
        border-right: none;
    }
</style>